# 主方法
from getFutureWeather import getFutureWeather
from statisticalHappinessIndex import happyIndex
from menu import menu
from weatherData import weatherData
from getWeatherVideo import getWeatherVideo

if __name__ == '__main__':

    while True:
        menu.menu()
        select = input('请输入操作：')
        if select == '1':
            city_name = tuple(input('请输入城市名称：').split(','))  # 以元组的方式输入城市名称
            print(city_name, type(city_name))
            year = input('请输入年份：')
            weatherData().get_weather_data(city_name, year)
            break
        elif select == '2':
            happyIndex.getHappyIndex()
            break
        elif select == '3':
            print('正在获取天气预报视频...')
            getWeatherVideo().getWeatherVideo()
            break
        elif select == '4':
            getFutureWeather().getFutureWeather()
            break
        else:
            print('输入错误')
